package com.example.config.web;import com.example.config.converter.EnumConverterFactory;import lombok.AllArgsConstructor;import org.springframework.boot.autoconfigure.condition.ConditionalOnWebApplication;import org.springframework.context.annotation.Configuration;import org.springframework.format.FormatterRegistry;import org.springframework.web.reactive.config.WebFluxConfigurer;/** * 添加自定义枚举转换配置 * * @author vains */@AllArgsConstructor@Configuration(proxyBeanMethods = false)@ConditionalOnWebApplication(type = ConditionalOnWebApplication.Type.REACTIVE)public class WebfluxConfig implements WebFluxConfigurer {    private final EnumConverterFactory<?, ?> enumConverterFactory;    @Override    public void addFormatters(FormatterRegistry registry) {        registry.addConverterFactory(enumConverterFactory);    }}